import request from '@/utils/request'

const api_name = '/inform'

export default {
    getFlashList() {
        return request.get(`${api_name}/list`)
    },
    // 新增获取通知列表接口
    getNotificationList(params: { page: number; size: number }) {
        return request.get(`${api_name}/notifications`, { params })
    },
    // 新增标记已读接口
    markAsRead(id: string) {
        return request.put(`${api_name}/read/${id}`)
    },
    // 新增获取未读数量接口
    getUnreadCount() {
        return request.get(`${api_name}/unread-count`)
    }
}